import java.util.Scanner;

public class Main1044 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int a = sc.nextInt();
        if (a < 10) {
            System.out.println("A");
        } else if (a >=10 && a < 20) {
            System.out.println("B");
        } else if (a >= 20 && a < 40) {
            System.out.println("C");
        } else if (a >= 40 && a < 50) {
            System.out.println("D");
        } else if (a >= 50 && a < 80) {
            System.out.println("E");
        }
    }
}
